﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Client.master" AutoEventWireup="true"
    CodeFile="article.aspx.cs" Inherits="Client_Article_article" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    <link type="text/css" rel="stylesheet" href="../../syntaxhighlighter_3.0.83/styles/shCore.css" />
    <link type="text/css" rel="stylesheet" href="../../syntaxhighlighter_3.0.83/styles/shThemeDefault.css" />
    <script type="text/javascript" src="../../syntaxhighlighter_3.0.83/scripts/shCore.js"></script>
    <script type="text/javascript" src="../../syntaxhighlighter_3.0.83/scripts/shBrushes.js"></script>
    <script type="text/javascript" src="../../ckeditor/ckeditor.js"></script>
    <link type="text/css" rel="Stylesheet" href="../../syntaxhighlighter_3.0.83/styles/shCoreDefault.css" />
    <script type="text/javascript">        SyntaxHighlighter.all();</script>
    <script src="../../Scripts/jquery-1.7.2.js" type="text/javascript"></script>
    <script type="text/javascript">
        $(function () {
            $("ul.commentlist li:nth-child(even)").addClass("even");
            $("ul.commentlist li:nth-child(odd)").addClass("odd");
            $(".comment-reply-link").click(function () {
                $("#ctl00_cph_RightMain_author").focus();
            });
            $("#ctl00_cph_RightMain_btn_Submit").click(function () {
                if ($("#ctl00_cph_RightMain_author").val() == "") {
                    alert("昵称不能为空！");
                    $("#ctl00_cph_RightMain_author").focus();
                    return false;
                }
                if ($("#ctl00_cph_RightMain_comment").val() == "") {
                    alert("评论内容不能为空！");
                    $("#ctl00_cph_RightMain_comment").focus();
                    return false;
                }
            });
            //            $("#ctl00_cph_RightMain_email").blur(function () {
            //                //alert("dfsd");
            //                var re = /\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/;
            //                var email = "345@qq.com";
            //                if (re.test(email)) {
            //                    alert("成功");
            //                }
            //                else {
            //                    alert("失败");
            //                }
            //            });
        });
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="cph_Nav" runat="Server">
    <ul id="secnav">
        <li><a href="../../index.aspx">index<span>首页</span></a></li>
        <li><a href="../code.aspx">code<span>代码</span></a></li>
        <li><a href="../database.aspx">database<span>数据库</span></a></li>
        <li><a href="../video.aspx">video<span>视频</span></a></li>
        <li><a href="../soft.aspx">soft<span>软件</span></a></li>
        <li><a href="../joy.aspx">joy<span>休闲一刻</span></a></li>
    </ul>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="cph_RightMain" runat="Server">
    <asp:Repeater ID="rpt_Nav" runat="server">
        <ItemTemplate>
            <div class="breadCrumb clearfix">
                您的位置：<a title="返回首页" rel="Prev" href="../../index.aspx">首页</a>&gt; <a rel="category tag"
                    title='<%#Eval("articleType_Name") %>' href='../<%#Eval("articleType_Name") %>.aspx'>
                    <%#Eval("articleType_nickName")%></a>&gt; <strong><a title='<%#Eval("article_title") %>'
                        rel="category tag" href='article.aspx?article_id=<%#Eval("article_id") %>&comment_count=<%#Eval("comment_count")%>'>
                        <%#Eval("article_title") %></a></strong>
            </div>
        </ItemTemplate>
    </asp:Repeater>
    <asp:Repeater ID="rpt_ArticlDetailed" runat="server">
        <ItemTemplate>
            <div class="article">
                <h1 id='<%#Eval("article_title") %>' class="title">
                    <a href='article.aspx?article_id=<%#Eval("article_id") %>&comment_count=<%#Eval("comment_count")%>'
                        rel="category tag" title='<%#Eval("article_title") %>'>
                        <%#Eval("article_title") %></a>
                </h1>
                <div class="post-meta-top">
                    <a rel="Next" rev="Prev" href='../other/author.aspx?users_id=<%#Eval("users_id") %>'
                        title='作者:<%#Eval("article_author") %>,查看作者详情。'>
                        <%#Eval("article_author") %>
                    </a>&nbsp;&nbsp;发表于&nbsp;&nbsp;<%#Eval("Article_StartTime")%>&nbsp;&nbsp; 分类：<a rel="Next"
                        rev="Prev" title='<%#Eval("articleType_Name") %>' href='../<%#Eval("articleType_Name") %>.aspx'><%#Eval("ArticleType_NickName")%></a>&nbsp;&nbsp;
                    <a rel="category tag" title='<%#Eval("article_title") %>' href='articleComment.aspx?article_id=<%#Eval("article_id") %>'>
                        <%#Eval("comment_count")%>&nbsp;&nbsp;条评论»</a>&nbsp;&nbsp;阅读数(<%#Eval("article_readerNumber")%>)<br />
                    标签：<a rel="tag" href='article.aspx?article_id=<%#Eval("article_id") %>&comment_count=<%#Eval("comment_count")%>'><%#Eval("article_title") %></a></div>
                <%-- <div class="inner_promot">
                    广告
                </div>--%>
                <%#Eval("article_content")%>
                <div style="overflow: hidden; padding-right: 20px;">
                    <div id="jiathis_style_32x32" style="float: right;">
                        <a class="jiathis_button_qzone" title="分享到QQ空间"></a><a class="jiathis_button_tqq"
                            title="分享到腾讯微博"></a><a class="jiathis_button_tsina" title="分享到新浪微博"></a><a class="jiathis_button_twitter"
                                title="分享到Twitter"></a><a class="jiathis_button_douban" title="分享到豆瓣"></a>
                        <a class="jiathis_button_xianguo" title="分享到鲜果"></a><a href="http://www.jiathis.com/share?uid=1623247"
                            class="jiathis jiathis_txt jtico jtico_jiathis" target="_blank"></a><a class="jiathis_counter_style">
                            </a>
                    </div>
                    <script type="text/javascript" src="http://v2.jiathis.com/code/jia.js?uid=1623247"
                        charset="utf-8"></script>
                </div>
                <div class="post_author clearfix">
                    <img class="avatar avatar-80 photo" width="80px" height="80px" src='../../Images/<%#Eval("Users_AvatarUrl")%>'
                        alt='你好！我叫<%#Eval("article_author")%>' />
                    <span>作者：</span><a title="代码管家网感谢你的观看,查看作者详情。" href='../other/author.aspx?users_id=<%#Eval("users_id") %>'><%#Eval("article_author")%></a><br />
                    <%#Eval("Users_Introduction")%>我的邮箱：<%#Eval("Users_Email")%><%--<span>我的e-Mail:<a href='mailto:<%#Eval("user_Email") %>'>发e-Mail给<%#Eval("article_author")%></a></span>--%></div>
            </div>
        </ItemTemplate>
    </asp:Repeater>
    <div id="comments">
        <h3>
            <label id="lb_commentCount" runat="server">
            </label>
            条评论</h3>
        <ul class="commentlist">
            <asp:Repeater ID="rpt_CommentList" runat="server">
                <ItemTemplate>
                    <li id='li-comment-<%#Eval("Comment_Id")%>' class="comment">
                        <div id='comment-<%#Eval("Comment_Id")%>'>
                            <div class="gravatar">
                                <img class="avatar avatar-32 photo" width="32px" height="32px" src='../../Images/<%#Eval("AvatarUrl")%>'
                                    alt='代码管家评论者：<%#Eval("Comment_Name")%>' />
                            </div>
                            <div class="comment-meta commentmetadata">
                                <span class="comment-author vcard"><cite class="fn"><em><a class="url" rel="external nofollow"
                                    href='<%#Eval("comment_url")%>' target="_blank" title="代码管家评论者">
                                    <%#Eval("comment_name")%>
                                </a></em></cite></span>&nbsp;&nbsp;发表于 <span>
                                    <%#Eval("Comment_DateTime")%></span>
                            </div>
                            <p>
                                <%#Eval("comment_content")%></p>
                            <div class="reply">
                                <a id='<%#Eval("Comment_Id")%>' href="javascript:void(0);" class="comment-reply-link">
                                    回复</a>
                            </div>
                        </div>
                    </li>
                </ItemTemplate>
            </asp:Repeater>
        </ul>
        <div class="comment-page clearfix">
            <%--评论的分页--%>
        </div>
        <div id="respond" class="box">
            <h3>
                发表评论</h3>
            <div class="cancel-comment-reply">
                <small></small>
            </div>
            <div id="commentform">
                <p>
                    <label for="author">
                        昵称<font color="red">(必填)</font></label>
                    <input id="author" maxlength="50" aria-required="true" name="author" runat="server"
                        type="text" />
                </p>
                <p>
                    <label for="email">
                        EMail(可选)</label>
                    <input id="email" type="text" runat="server" maxlength="50" name="email" />
                </p>
                <p>
                    <label for="url">
                        个人网站(可选)</label>
                    <input id="url" type="text" value="http://" maxlength="100" runat="server" name="url" />
                </p>
                <div class="comment_bd">
                    <textarea id="comment" runat="server" tabindex="7" rows="6" cols="50" name="comment"
                        style="width: 780px; height: 100px;"></textarea>
                </div>
                <div class="comment_ft">
                    <asp:Button ID="btn_Submit" runat="server" Text="提交" Style="background: none repeat scroll 0 0 #669966;
                        border: 0 none; color: #ffffff; cursor: pointer; font: bold 14px '微软雅黑',helvetica,Arial;
                        margin: 10px 10px 0 0; width: 100px;" OnClick="btn_Submit_Click" />
                </div>
            </div>
        </div>
    </div>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="chp_LeftMain" runat="Server">
    <h3>
        热门文章</h3>
    <ul>
        <asp:Repeater ID="rpt_Top" runat="server">
            <ItemTemplate>
                <li><a title='<%#Eval("article_title")%>' href='article.aspx?article_id=<%#Eval("article_id") %>&comment_count=<%#Eval("comment_count")%>'
                    rel="Next"><span class="wpp-post-title">
                        <%#Eval("article_title")%></span></a> </li>
            </ItemTemplate>
        </asp:Repeater>
    </ul>
    <h3>
        系列文章</h3>
    <ul>
        <asp:Repeater ID="rpt_SeriesArticle" runat="server">
            <ItemTemplate>
                <li><a title='<%#Eval("SeriesArticle_Name") %>' href='Article/article.aspx?article_id=<%#Eval("Article_Id") %>&comment_count=<%#Eval("comment_count")%>'
                    rel="Next" rev="Index"><span>
                        <%#Eval("SeriesArticle_Name") %></span></a> </li>
            </ItemTemplate>
        </asp:Repeater>
    </ul>
    <h3>
        网站信息</h3>
    <ul>
        <li>文章总数：<%=GetArticleCount() %></li>
        <li>评论总数：<%=CommentCount() %></li>
        <li>网站当前在线人数：<%=GetOnline() %></li>
        <li>站长：追夢</li>
        <li>QQ交流群1：190500421</li><li>QQ交流群2：158430651</li><li>QQ交流群3：205886913</li>
    </ul>
    <h3>
        友情链接</h3>
    <ul class="xoxo blogroll">
        <asp:Repeater ID="rpt_Links" runat="server">
            <ItemTemplate>
                <li><a title='<%#Eval("Links_Name")%>' href='<%#Eval("Links_Url")%>' rel="Next" rev="Prev"
                    target="_blank">
                    <%#Eval("Links_Name")%></a> </li>
            </ItemTemplate>
        </asp:Repeater>
    </ul>
</asp:Content>
